package com.jzo2o.market.controller.operation;


import com.jzo2o.common.model.PageResult;
import com.jzo2o.market.model.domain.Coupon;
import com.jzo2o.market.model.dto.request.CouponOperationPageQueryReqDTO;
import com.jzo2o.market.service.ICouponService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController("CouponController")
@RequestMapping("/operation/coupon")
@Api(tags = "运营端 - 优惠劵相关接口 - 领取记录")
public class CouponController {
    @Resource
    private ICouponService couponService;

    /**
     * 分页查询优惠劵领取记录
     */
    @GetMapping("/page")
    @ApiOperation("分页查询优惠劵领取记录")
    public PageResult<Coupon> page(CouponOperationPageQueryReqDTO couponOperationPageQueryReqDTO) {
        return couponService.addpage(couponOperationPageQueryReqDTO);
    }
}
